package com.uestc.soft.mapper;

import com.uestc.soft.pojo.Port;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface PortMapper {
    Port selectById(Integer id);

    void hy_insert(@Param("port") Port port);

    List<Port> hy_selectByPage(@Param("index") int index,
                            @Param("limit") int limit,
                            @Param("portNumber") String portNumber,
                            @Param("portProtocol") String portProtocol,
                            @Param("processName") String processName);

    int hy_selectCount(@Param("portNumber") String portNumber,
                    @Param("portProtocol") String portProtocol,
                    @Param("processName") String processName);

    void hy_deleteById(Integer id);

    void updatePort(@Param("id") Integer id,
                    @Param("portNumber") Integer portNumber,
                    @Param("portProtocol") String portProtocol,
                    @Param("processName") String processName,
                    @Param("numberOfHostMachines") Integer numberOfHostMachines
                    );
}
